package com.yuju.persist.util;

import com.yuju.common.util.twitter.IDGenerator.IdWorker;

public class IdWorkerInstance {
	
	private IdWorkerInstance() {
		
	}

	private static final IdWorker idWorker = new IdWorker(1, 1);
	
	private static IdWorker getInstance() {
		return idWorker;
	}
	
	public static Long getId() {
		return getInstance().nextId();
	}
	
	public static String getIdStr() {
		return getInstance().nextId() + "";
	}
	public static void main(String agre[]){
		int i=0;
		while(i<10){
		System.out.println(IdWorkerInstance.getIdStr());
		i++;
		}
	}
}
